package other;

import java.util.*;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int m = sc.nextInt();
        int n = sc.nextInt();
        String alphabet = "ABCDEFGHIJKLMNOPQRSTUVWXYZ";
        String alphabetReverse = "ZYXWVUTSRQPONMLKJIHGFEDCBA";
        String row = alphabet.substring(0,n);
        for (int i = 0; i < m; i++) {
            row = alphabetReverse.substring(alphabet.length()-i-1,alphabet.length()-1) + alphabet.substring(0,n-i) ;
            System.out.println(row);
        }
    }

    static void printArr(int[] arr) {
        StringBuffer sb = new StringBuffer();
        for (int a : arr) {
            sb.append(a);
        }
        System.out.println(sb.toString());
    }

    static void addArr(int[] arr) {
        for (int i = arr.length - 1; i >= 0; i--) {
            if (arr[i]==0){
                arr[i]=1;
                break;
            }else {
                arr[i]=0;
            }
        }
    }

    static long Fibonacci(long n) {
        if (n == 1 || n == 2) {
            return 1;
        }
        long next = 0;
        long f1 = 1;
        long f2 = 1;
        for (long i = 3; i <= n; i++) {
            next = (f1 + f2) % 10007;
            f1 = f2;
            f2 = next;
        }
        return next;
    }

    static void quickSort(int[] arr, int low, int high) {
        if (low < high) {
            int mid = partition(arr, low, high);
            quickSort(arr, low, mid - 1);
            quickSort(arr, mid + 1, high);
        }
    }

    static int partition(int[] arr, int low, int high) {
        int temp = arr[low];
        while (low < high) {
            while (arr[high] >= temp && low < high) {
                high--;
            }
            arr[low] = arr[high];
            while (arr[low] <= temp && low < high) {
                low++;
            }
            arr[high] = arr[low];
        }
        arr[low] = temp;
        return low;
    }
}

